Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented special handling for -nodebug flag #1014

Merged
merged 2 commits into from
Apr 27, 2021
Merged

Conversation

a-bezrukov
Copy link
Contributor

PR intention

Suppress all the log messages except those start with "ERROR:".

Code changes brief

Added a temporary flag fNoDebug. Bitcoin 0.17 introduces a redesign which have this logic fixed.

@a-bezrukov a-bezrukov changed the title Implemented special handling for -nodebug flag. Closes #1011 Implemented special handling for -nodebug flag Apr 13, 2021
src/util.cpp Outdated
if (str.size() < 6)
return 0;
else if (strncmp(str.data(), "ERROR:", 6) != 0)
return 0;
Copy link
Contributor

@psolstice psolstice Apr 27, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there is much more elegant way to do the comparison

if (str.compare(0, 6, "ERROR:") != 0)
  return 0;

@lgtm-com
Copy link

lgtm-com bot commented Apr 27, 2021

This pull request introduces 3 alerts when merging 8482413 into e0bc12b - view on LGTM.com

new alerts:

  • 3 for Unused static function

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants